import BeDefeatedView_Generate from "../ui-generate/BeDefeatedView_generate";

export class BeDefeatedView extends BeDefeatedView_Generate{
    private timer = 0

    onShow(){
        this.canUpdate = true
    }

    setInfo(name:string){
        this.timer = 2
        this.txt_context.text = `${name}被淘汰!`
    }

    onUpdate(dt:number){
        this.timer -= dt
        if(this.timer <= 0){
            UIService.hideUI(this)
        }
    }
}